﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Remoting.Channels;
using System.Text;
using System.Threading.Tasks;

namespace homework2.PlaneFigure
{
    internal class Rectangle:PlaneFigure
    {
        private int Length;
        private int Width;
        public Rectangle(int length, int width)
        {
            Length = length;
            Width = width;
        }
        public override double getArea()
        {
            return Length*Width;
        }

        public override bool isLegal()
        {
            return Length > Width && Width > 0;
        }
    }
}
